home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.cs.arizona.edu
/
ftp.cs.arizona.edu.tar
/
ftp.cs.arizona.edu
/
icon
/
newsgrp
/
group02b.txt
/
000104_icon-group-sender_Thu Nov 7 16:44:19 2002.msg
< prev
next >
Wrap
Internet Message Format
|
2003-01-02
|
2KB
Return-Path: <icon-group-sender>
Received: (from root@localhost)
by baskerville.CS.Arizona.EDU (8.11.1/8.11.1) id gA7Ngh201603
for icon-group-addresses; Thu, 7 Nov 2002 16:42:43 -0700 (MST)
Message-Id: <200211072342.gA7Ngh201603@baskerville.CS.Arizona.EDU>
From: Art Eschenlauer <art.eschenlauer@sufsys.com>
To: "'Ed L Cashin '" <ecashin@uga.edu>,
"'icon-group@CS.Arizona.EDU'"
<icon-group@cs.arizona.edu>
Cc: "'websitewill@cox-internet.com'" <websitewill@cox-internet.com>
Subject: RE: Question about Icon
Date: Thu, 7 Nov 2002 16:55:16 -0600
Errors-To: icon-group-errors@cs.arizona.edu
Status: RO
The easy way is to use Unicon
<http://unicon.sourceforge.net>
because it provides the filepair() builting function.
The POSIX extensions for Icon do the same - at least according to:
<http://www.drones.com/unicon/>
-----Original Message-----
From: Ed L Cashin
To: WebsiteWill
Cc: icon-group@CS.Arizona.EDU
Sent: 11/6/02 6:41 PM
Subject: Re: Question about Icon
"WebsiteWill" <websitewill@cox-internet.com> writes:
> Is there a way to have an Icon Program take as input a Scheme
> program as a basic string, do some conversions to that string and
> then output the new string to a Scheme interpreter/compiler and run
> it then finally take the output from Scheme as a new set of input
> into the same Icon Program?
I was interested in your question, so I looked up info on pipes in
icon, but it looks like there is no easy way to launch another process
inside of icon and then do both writing to and reading from the another
process.
(Perl has to jump through hoops to support this -- see the perlipc
manpage.)
Please anyone chime in if there is an easy way to launch a process in
icon code and then do I/O to and from the process.
You could, of course, manipulate the string, write it to a file on
disk, run the scheme interpreter from icon with popen or open with the
pipe mode (so that the scheme interpreter is reading from the file),
and then read the output from the scheme interpreter through the
pipe's filehandle.
--
--Ed L Cashin | PGP public key:
ecashin@uga.edu | http://noserose.net/e/pgp/